import * as index from '@/api/index.js'
export default {
	data() {
		return {
			form:{
				content:''
			}
		}
	},
	
	onShow() {
	
	},
	onLoad(option) {
	
	},

	methods: {
		submit(){
			let that = this
			uni.showModal({
				content: '是否确认提交',
				success: function (res) {
					if (res.confirm) {
						index.feedback(that.form).then(res=>{
							that.$tools.toast('提交成功')
							setTimeout(()=>{
								that.$tools.back(1)
							},1000)
						})
					} else if (res.cancel) {
						console.log('用户点击取消');
					}
				}
			});

		}
	}
}